<div class="row">
  <div class="col-lg-8">
    <div class="panel panel-primary">
      <div class="panel-heading">应用服务注册</div>
      <div class="panel-body" ng-init="send('uddi.index', {})">
        <table class="table">
          <tr>
            <th>应用</th>
            <th>服务地址</th>
            <th></th>
          </tr>
          <tr ng-repeat="e in uddi_index">
            <td style="width: 20%"><b>{{e.appid}}</b></td>
            <td style="width: 30%">
              <div ng-switch on="e.editing" ng-init="e.editing = false;">
                <div ng-switch-when="false">{{e.url}}</div>
                <div ng-switch-default>
                  <form name="createForm" class="form-inline" role="form" ng-submit="send('uddi.edit', e)">
                    <input type="text" class="form-control" ng-model="e.url">
                    <input class="btn btn-default" type="submit" ng-disabled="createForm.$invalid"/>
                    <a href ng-click="e.editing = false; send('uddi.index', {});">取消</a>
                  </form>
                </div>
              </div>
            </td>
            <td>
              <small>
                <a href ng-click="e.editing = true;">
                  <i class="fa fa-edit fa-1x text-warning pull-right"></i>
                </a>
              </small>
            </td>
          </tr>
        </table>
      </div>
    </div>
  </div>
</div>
